<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>045-改变所有元素样式.html</title>
</head>
<body>
	<ul>
			<li>1</li>
			<li>2</li>
			<li>3</li>
			<li>4</li>
			<li>5</li>
			<li>6</li>
			<li>7</li>
			<li>8</li>
			<li>9</li>
			<li>10</li>
			<li>11</li>
			<li>12</li>
			<li>13</li>
			<li>14</li>
			<li>15</li>
			<li>16</li>
			<li>17</li>
			<li>18</li>
			<li>19</li>
			<li>20</li>
		</ul>	
</body>
<script>
	var aLi = document.getElementsByTagName('li');
	console.log(aLi);
/*
	aLi[0].style.color = "red";
	aLi[1].style.color = "red";
	aLi[2].style.color = "red";
	aLi[3].style.color = "red";
	aLi[4].style.color = "red";
	aLi[5].style.color = "red";
*/
	for(var i = 0;i < aLi.length;i++){
		aLi[i].style.color = "skyblue";
	}
</script>
</html>